/**
 * 2016，thor.com，all rights reserved。
 * 
 * Project：		palmmall-api
 * Filename：	ARepairService.java
 * Created：		2016年9月12日
 * Creator：		wolv
 */
package com.thor.palmmall.rest.repair;

import java.util.List;

import javax.ws.rs.Consumes;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;

import com.thor.commons.entity.BeanOperateInfo;
import com.thor.commons.entity.UCN;
import com.thor.commons.exception.ThorServiceException;
import com.thor.commons.query.QueryResult;
import com.thor.palmmall.rest.common.AAssignInfo;
import com.thor.palmmall.rest.common.ASignInInfo;
import com.thor.palmmall.rest.common.AUserGroupLoadParam;

/**
 * @author wolv
 *
 */
@Path("/repair")
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
public interface ARepairService {

  @GET
  @Path(value = "/config/{storeUuid}")
  ARepairConfig getConfig(@PathParam("storeUuid") String storeUuid) throws ThorServiceException;

  @POST
  @Path(value = "/materials")
  QueryResult<AMaterial> queryMaterial(AMaterialQueryParam param) throws ThorServiceException;

  @GET
  @Path(value = "/servicemans")
  List<UCN> serviceMans() throws ThorServiceException;

  @POST
  String create(ARepairBill bill, @QueryParam("") BeanOperateInfo operateInfo)
      throws ThorServiceException;

  @POST
  @Path(value = "/{id}")
  ARepairBill get(@PathParam("id") String id, AUserGroupLoadParam param)
      throws ThorServiceException;

  @POST
  @Path(value = "/save")
  void save(ARepairBill bill, @QueryParam("") BeanOperateInfo operateInfo)
      throws ThorServiceException;

  @POST
  @Path(value = "/query")
  QueryResult<ARepairBill> query(ARepairBillQueryParam param) throws ThorServiceException;

  @POST
  @Path(value = "/signIn")
  void signIn(ASignInInfo signInInfo) throws ThorServiceException;

  @POST
  @Path(value = "/assign")
  void assign(AAssignInfo assignInfo) throws ThorServiceException;

  @GET
  @Path(value = "/queryOutgoingState")
  String[] queryOutgoingState() throws ThorServiceException;

}
